Microsoft® Visual Basic® Scripting Edition
Chr Function
Language Reference

See Also


Description
Returns the character associated with the specified ANSI character code.

Syntax

Chr(charcode)

The charcode argument is a number that identifies a character.

Remarks

Numbers from 0 to 31 are the same as standard, nonprintable ASCII codes. For example, Chr(10) returns a linefeed character.


Note  Another function (ChrB) is provided for use with byte data contained in a string. Instead of returning a character, which may be one or two bytes, ChrB always returns a single byte. ChrW is provided for 32-bit platforms that use Unicode characters. Its argument is a Unicode (wide) character code, thereby avoiding the conversion from ANSI to Unicode.


© 1997 Microsoft Corporation. All rights reserved. Legal Notices.